import request from '@/utils/request'

// 账号密码登录
export function login(data) {
  return request({
    url: '/cms/login/login',
    method: 'post',
    data
  })
}

// 手机号登录
export function mobileLogin(data) {
  return request({
    url: '/cms/login/mobilelogin',
    method: 'post',
    data
  })
}

// 用户注册
export function register(data) {
  return request({
    url: '/cms/login/register',
    method: 'post',
    data
  })
}

// 重置密码
export function resetPassword(data) {
  return request({
    url: '/cms/login/resetpwd',
    method: 'post',
    data
  })
}

// 微信登录
export function wxLogin(data) {
  return request({
    url: '/cms/login/wxLogin',
    method: 'post',
    data
  })
}

// 微信手机号登录
export function wechatMobileLogin(data) {
  return request({
    url: '/cms/login/wechatMobileLogin',
    method: 'post',
    data
  })
}

// APP登录
export function appLogin(data) {
  return request({
    url: '/cms/login/appLogin',
    method: 'post',
    data
  })
}

// 获取微信OpenID
export function getWechatOpenid(data) {
  return request({
    url: '/cms/login/getWechatOpenid',
    method: 'post',
    data
  })
}

// 获取微信手机号
export function getWechatMobile(data) {
  return request({
    url: '/cms/login/getWechatMobile',
    method: 'post',
    data
  })
}